{include file='common/header'}

<div class="container">
    <div class="row">
        <div class="col-md-9 col-sm-12 hy-main-content">
            <div class="hy-layout clearfix">
                <div class="hy-video-head"><span class="text-muted pull-right hidden-xs">当前第<span
                        class="text-color">“{:input('page')?:1}”</span>页</span><h4 class="margin-0">搜索到与<span
                        class="text-color">“{$text}”</span>相关的<span class="text-color">“{$total}”</span>条结果</h4></div>
                <div class="hy-video-details active clearfix">
                    {foreach $movies as $k=>$info}
                    <div class="item clearfix">
                        <dl class="content">
                            <dt><a class="videopic" href="{:url('/details',['movie_id'=>$info['id']])}"
                                   style="background: url({$info.poster})  no-repeat; background-position:50% 50%; background-size: cover;"><span
                                    class="play hidden-xs"></span><span class="note textbg">{$info.resolution}</span></a></dt>

                            <dd class="clearfix">
                                <div class="head"><h3><a href="{:url('/details',['movie_id'=>$info['id']])}">{$info.title}</a></h3></div>
                                <div class="score">
                                    <!--<div>-->
                                        {php}$grade = round($info['grade'])/2;{/php}

                                        {for start='0' end='$grade' name='v'}
                                        <img iid="1" src="/index/images/star0.gif" >
                                        {/for}
                                        {for start='0' end='5-$grade' name='v'}
                                        <img iid="2" src="/index/images/star1.gif" >
                                        {/for}
                                        <span class="branch">{$info.grade}</span>

                                    <!--</div>-->
                                    <script type="text/javascript">
//                                        var str = "9.1%"
//                                        document.getElementById("score-1").style.width = (str.replace(".", ""))
                                    </script>
                                </div>
                                <ul>
                                    {php} $actors = explode(',',$info['actors']) {/php}
                                    <li><span class="text-muted">主演：</span>
                                        {foreach $actors as $v}
                                        <a href='{:url("/search",["keyword"=>$v])}'>{$v}</a>&nbsp;
                                        {/foreach}
                                    </li>

                                    <li><span class="text-muted">导演：</span><span>{$info.directors}</span></li>
                                    <li class="col-md-6 col-sm-6 hidden-xs padding-0"><span class="text-muted">地区：</span>{$info.region_name}
                                    </li>
                                    <li class="col-md-6 col-sm-6 hidden-xs padding-0"><span class="text-muted">类型：</span><a
                                            href="/search.php?searchtype=5&tid=12" title="{$info.type_name}片">{$info.type_name}片</a></li>
                                    <li class="col-md-6 hidden-sm hidden-xs padding-0"><span class="text-muted">语言：</span>{$info.language}
                                    </li>
                                    <li class="col-md-6 hidden-sm hidden-xs padding-0"><span class="text-muted">年份：</span>{$info.movie_time|date='Y'}
                                    </li>
                                </ul>
                                <div class="block"><a class="text-muted" href="{:url('/details',['movie_id'=>$info['id']])}">查看详情 <i
                                        class="icon iconfont icon-right"></i> </a></div>
                            </dd>
                        </dl>
                    </div>
                    {/foreach}
                </div>

                <div class="hy-page clearfix">
                    {$movies|raw}
                </div>
            </div>
        </div>
        <div class="col-md-3 col-sm-12 hy-main-side hidden-sm hidden-xs">
            <div class="hy-layout clearfix">
                <div class="hy-video-ranking side clearfix">
                    <div class="head"><a class="text-muted pull-right" href="{:url('/movie')}">更多 <i
                            class="icon iconfont icon-right"></i></a><h4><i
                            class="icon iconfont icon-top text-color"></i> 电影排行榜</h4></div>
                    <div class="item">
                        <ul class="clearfix">
                            {foreach $tops as $k=> $v}
                            <li class="text-overflow">
                                <span class="pull-right text-color">{$v.grade}</span>
                                <a href="{:url('/details',['movie_id'=>$v['id']])}" title="{$v.title}"><em
                                        class="number {if $k<3}active{/if}">{$k+1}</em>{$v.title}</a>
                            </li>
                            {/foreach}


                        </ul>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>
<script>
    var swiper = new Swiper('.hy-slide', {
        pagination: '.swiper-pagination',
        paginationClickable: true,
        autoplay: 3000,
    });
</script>
{include file='common/foot'}


